package com.jumper.study.front.dto.resp;

import java.util.ArrayList;
import java.util.List;

public class LessonCategoryResp {
    private Integer id;

    private String title;

    private List<LessonCategoryResp> children;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public List<LessonCategoryResp> getChildren() {
        return children;
    }

    public void setChildren(List<LessonCategoryResp> children) {
        this.children = children;
    }

    public void addChild(LessonCategoryResp child) {
        if (children == null) {
            children = new ArrayList<>();
        }
        children.add(child);
    }
}
